package com.zensun.system.domain;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.zensun.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Null;

/**
 * 字典类型表 sys_dict_type
 *
 * @author gmk
 */
@ApiModel("字典类型表")
@Data
@TableName("sys_dict_type")
public class SysDictType extends BaseEntity<SysDictType> {
    private static final long serialVersionUID = 1L;

    /**
     * 字典主键
     */
    @ApiModelProperty("字典编号")
    @Null(message = "字典主键必须为空", groups = AddGrop.class)
    @NotNull(message = "字典主键不能为空", groups = UpdateGrop.class)
    @TableId
    private Long dictId;

    /**
     * 字典名称
     */
    @NotBlank(message = "字典类型名称不能为空", groups = {AddGrop.class, UpdateGrop.class})
    @ApiModelProperty("字典名称")
    private String dictName;

    /**
     * 字典类型
     */
    @NotBlank(message = "字典类型不能为空", groups = AddGrop.class)
    @Null(message = "字典类型不能修改", groups = UpdateGrop.class)
    @ApiModelProperty("字典类型")
    private String dictType;

    /**
     * 状态（0正常 1停用）
     */
    @NotNull(message = "部门名称不能为空", groups = {AddGrop.class, UpdateGrop.class})
    @ApiModelProperty("状态（0正常 1停用）")
    private String status;


}
